
<!DOCTYPE html>
<html>
  <head>
    <title>Beego Framework Tutorials - 1 - Introduction to Beego</title>
    <meta charset='utf-8'>
    <script src='static/slides.js'></script>
  </head>

  <body style='display: none'>

    <section class='slides layout-widescreen'>
      
      <article>
        <h1>Beego Framework Tutorials - 1 - Introduction to Beego</h1>
        <h3>A Go HTTP framework for developing HTTP application rapidly</h3>
        
        
          <div class="presenter">
            
  
  <p>
    By Lei Cao
  </p>
  

          </div>
        
      </article>
      
  
  
      <article>
      
        <h3>Content</h3>
        
  <ul>
  
    <li>Why do we create <b>beego</b>?</li>
  
    <li>What can we do with <b>beego</b>?</li>
  
    <li>Where will <b>beego</b> lead to in the future?</li>
  
    <li>How to install and config <b>beego</b>?</li>
  
    <li>When can I get started with <b>beego</b>?</li>
  
  </ul>

      
      </article>
  
  
  
      <article>
      
        <h3>Why do we create beego?</h3>
        
  
  <p>
    1. Astaxie want to create a framework while he was writing his book.
  </p>
  
<p class="link"><a href="https://github.com/astaxie/build-web-application-with-golang" target="_blank">Build Web Application with Golang</a></p>
  
  <p>
    2. It is inspired by tornado, sinatra and flask.
  </p>
  

      
      </article>
  
  
  
      <article>
      
        <h3>What can we do with beego?</h3>
        
  
  <p>
    <b>beego</b> is a http application framework
  </p>
  

  
  <p>
    Why it&#39;s called http framework other than web framework?
  </p>
  

  
  <p>
    The reason is <b>beego</b> suits for any kinds of http services: api services, web backend, game development etc.
  </p>
  

      
      </article>
  
  
  
      <article>
      
        <h3>beego&#39;s Key Features</h3>
        
  <ul>
  
    <li>High performance. The fastest Go framework out there now.</li>
  
  </ul>
<p class="link"><a href="http://www.techempower.com/benchmarks/#section=data-r9&amp;hw=i7&amp;test=json" target="_blank">Web Framework Benchmarks</a></p>
  <ul>
  
    <li>High-productivity, many components, highly decoupled</li>
  
    <li>Tons of live products. 360，weico，jd，opera ...</li>
  
    <li>RESTful model with customizable actions</li>
  
    <li>Stable; active update; continuous maintainace</li>
  
    <li>Pretty good documents</li>
  
  </ul>

      
      </article>
  
  
  
      <article>
      
        <h3>Where will beego lead to in the future?</h3>
        
  <ul>
  
    <li>Highly modular. Improving existent modules and developing more new modules</li>
  
    <li>Light core framework. <b>beego</b> is formed by many modules now. Will make it even lighter. Any part of MVC can be replaced.</li>
  
    <li>Enhance routing. Compating with other framework&#39;s service. For example you can create a module in Martini and call it in <b>beego</b>.</li>
  
    <li>Enhance <code>bee</code> tool. Automating the development even more.</li>
  
  </ul>

      
      </article>
  
  
  
      <article>
      
        <h3>How to install and config beego?</h3>
        
  
  <p>
    <b>beego</b> is the framework, <b>bee</b> is the developing tool.
  </p>
  

  
  <div class="code"><pre>go get github.com/astaxie/beego
go get github.com/beego/bee</pre></div>
  

      
      </article>
  
  
  
      <article>
      
        <h3>Frequently happened issues while install beego:</h3>
        
  <ul>
  
    <li><b>GOPATH</b> related issues.</li>
  
    <li><b>bee</b> tool realted issues.</li>
  
  </ul>

      
      </article>
  
  
  
      <article>
      
        <h3>Testing if installed sucessfully</h3>
        
  
  <p>
    Type <code>bee</code> in command line
  </p>
  

  
  <div class="code"><pre>Bee is a tool for managing beego framework.

Usage:

    bee command [arguments]

The commands are:

    new         create an application base on beego framework
    run         run the app which can hot compile
    pack        compress an beego project
    api         create an api application base on beego framework
    router      auto-generate routers for the app controllers
    test        test the app
    bale        packs non-Go files to Go source files</pre></div>
  
<p class="link"><a href="http://beego.me/docs/install/bee.md" target="_blank">bee tool document</a></p>
      
      </article>
  
  
  
      <article>
      
        <h3>When can I get started with beego? The answer is now!</h3>
        
  
  <div class="code"><pre>bee new beegoProject

bee run watchall</pre></div>
  

      
      </article>
  
  
  
      <article>
      
        <h3>Directory explication</h3>
        
  
  <div class="code"><pre>.
|-- conf
|   `-- app.conf
|-- controllers
|   `-- default.go
|-- main.go
|-- models
|-- routers
|   `-- router.go
|-- static
|   |-- css
|   |-- img
|   `-- js
|-- tests
|   `-- default_test.go
`-- views
    `-- index.tpl</pre></div>
  

      
      </article>
  
  
  
      <article>
      
        <h3>Links</h3>
        <p class="link"><a href="https://github.com/beego/tutorial" target="_blank">Beego Framework Toturials</a></p>
      
      </article>
  
  

      <article>
        <h3>Thank you</h1>
        
          <div class="presenter">
            
  
  <p>
    By Lei Cao
  </p>
  
<p class="link"><a href="http://github.com/lei-cao" target="_blank">http://github.com/lei-cao</a></p>
          </div>
        
      </article>

  </body>
  
</html>
